package com.xcf.service.business.common.boatcompanyfixedsurcharge.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.xcf.dao.DaoSupport;
import com.xcf.service.business.common.boatcompanyfixedsurcharge.BoatCompanyFixedSurchargeService;
import com.xcf.util.PageData;
@Service
public class BoatCompanyFixedSurchargeServiceImpl implements BoatCompanyFixedSurchargeService{
	@Resource(name="daoSupport")
	private DaoSupport dao;
	@SuppressWarnings("unchecked")
	@Override
	public List<PageData> findInfo(PageData pd) throws Exception {
		
		return (List<PageData>) dao.findForList("BoatCompanyFixedSurcharge.findInfo", pd);
	}
	@Override
	public List<PageData> findBoxType() throws Exception {
		// TODO Auto-generated method stub
		return (List<PageData>) dao.findForList("BoatCompanyFixedSurcharge.findBoxType", null);
	}
	@Override
	public List<PageData> findBoatCompanyAndUnit() throws Exception {
		// TODO Auto-generated method stub
		return (List<PageData>) dao.findForList("BoatCompanyFixedSurcharge.findBoatCompanyAndUnit", null);
	}
	@Override
	public List<PageData> findRoute() throws Exception {
		// TODO Auto-generated method stub
		return (List<PageData>) dao.findForList("BoatCompanyFixedSurcharge.findRoute",null);
	}
	@Override
	public List<PageData> findFee() throws Exception {
		// TODO Auto-generated method stub
		return (List<PageData>) dao.findForList("BoatCompanyFixedSurcharge.findFee", null);
	}
	@Override
	public void saveInfo(PageData pd) throws Exception {
		dao.save("BoatCompanyFixedSurcharge.saveInfo", pd);
		
	}
	@Override
	public void updateInfo(PageData pd) throws Exception {
		dao.update("BoatCompanyFixedSurcharge.updateInfo", pd);
		
	}
	@Override
	public void deleteInfo(PageData pd) throws Exception {
		dao.delete("BoatCompanyFixedSurcharge.deleteInfo", pd);
		
	}
	@Override
	public void updataUnitInfo(PageData pd) throws Exception {
		dao.update("BoatCompanyFixedSurcharge.updateUnitInfo", pd);
		
	}
	@Override
	public PageData findInfoById(String ID) throws Exception {
		
		return (PageData) dao.findForObject("BoatCompanyFixedSurcharge.findInfoById", ID);
	}
	@Override
	public PageData findInfoByInfo(PageData pd) throws Exception {
		
		return (PageData) dao.findForObject("BoatCompanyFixedSurcharge.findInfoByInfo", pd);
	}
	@Override
	public void updateInfoByInfo(PageData pd) throws Exception {
		dao.update("BoatCompanyFixedSurcharge.updateInfoByInfo", pd);
		
	}

}
